package com.weibo.resp;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.weibo.entity.BlogImg;
import com.weibo.entity.User;
import lombok.Data;

import java.util.Date;
import java.util.List;

@Data
public class BlogDetailAndCommentsResp {

    @Data
    public class CommentResp{
        private int commentId;
        private User user;
        private String content;

        @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
        private Date createdTime;
    }

    private int blogId;
    private User user;
    private String content;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createdTime;
    private List<BlogImg> imgs;
    private List<CommentResp> commentList;
}
